import request from '@/utils/request'

// 查询客户申请列表
export function listCustomerapply(query) {
  return request({
    url: '/customerapply/customerapply/list',
    method: 'get',
    params: query
  })
}

// 查询客户申请详细
export function getCustomerapply(id) {
  return request({
    url: '/customerapply/customerapply/' + id,
    method: 'get'
  })
}

// 新增客户申请
export function addCustomerapply(data) {
  return request({
    url: '/customerapply/customerapply/add',
    method: 'post',
    data: data
  })
}

// 修改客户申请
export function updateCustomerapply(data) {
  return request({
    url: '/customerapply/customerapply/update',
    method: 'put',
    data: data
  })
}

// 审核申请 1是同意2是拒绝
export function agreeCustomerApply(data) {
  return request({
    url: '/customerapply/customerapply/agree',
    method: 'post',
    data: data
  })
}

// 删除客户申请
export function delCustomerapply(id) {
  return request({
    url: '/customerapply/customerapply/' + id,
    method: 'delete'
  })
}
